<!DOCTYPE html>
<html lang="en-US">
<head>
    <meta charset="UTF-8"/>
    <meta name="viewport" content="width=device-width, initial-scale=1">
    <meta name="language" content="en" />
        <link href="./assets/ffd55088/css/bootstrap.css" rel="stylesheet">
<link href="./assets/5cf9384a/solarized_light.css" rel="stylesheet">
<link href="./assets/6c54116e/style.css" rel="stylesheet">
<script src="./assets/a44cef0f/jquery.js"></script>
<script src="./assets/ffd55088/js/bootstrap.js"></script>
<script src="./assets/8ac4e28a/jssearch.js"></script>    <title>ActiveForm, yii\bootstrap\ActiveForm - Yii Framework 2.0 API Documentation</title>
</head>
<body>

<div class="wrap">
    <nav id="w10641" class="navbar-inverse navbar-fixed-top navbar" role="navigation"><div class="navbar-header"><button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#w10641-collapse"><span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span></button><a class="navbar-brand" href="./index.html">Yii Framework 2.0 API Documentation</a></div><div id="w10641-collapse" class="collapse navbar-collapse"><ul id="w10642" class="navbar-nav nav"><li><a href="./index.html">Class reference</a></li>
<li class="dropdown"><a class="dropdown-toggle" href="#" data-toggle="dropdown">Extensions <b class="caret"></b></a><ul id="w10643" class="dropdown-menu"><li><a href="./ext-apidoc-index.html" tabindex="-1">apidoc</a></li>
<li><a href="./ext-authclient-index.html" tabindex="-1">authclient</a></li>
<li><a href="./ext-bootstrap-index.html" tabindex="-1">bootstrap</a></li>
<li><a href="./ext-codeception-index.html" tabindex="-1">codeception</a></li>
<li><a href="./ext-debug-index.html" tabindex="-1">debug</a></li>
<li><a href="./ext-elasticsearch-index.html" tabindex="-1">elasticsearch</a></li>
<li><a href="./ext-faker-index.html" tabindex="-1">faker</a></li>
<li><a href="./ext-gii-index.html" tabindex="-1">gii</a></li>
<li><a href="./ext-imagine-index.html" tabindex="-1">imagine</a></li>
<li><a href="./ext-jui-index.html" tabindex="-1">jui</a></li>
<li><a href="./ext-mongodb-index.html" tabindex="-1">mongodb</a></li>
<li><a href="./ext-redis-index.html" tabindex="-1">redis</a></li>
<li><a href="./ext-smarty-index.html" tabindex="-1">smarty</a></li>
<li><a href="./ext-sphinx-index.html" tabindex="-1">sphinx</a></li>
<li><a href="./ext-swiftmailer-index.html" tabindex="-1">swiftmailer</a></li>
<li><a href="./ext-twig-index.html" tabindex="-1">twig</a></li></ul></li>
<li><a href="./guide-README.html">Guide</a></li></ul><div class="navbar-form navbar-left" role="search">
  <div class="form-group">
    <input id="searchbox" type="text" class="form-control" placeholder="Search">
  </div>
</div>
</div></nav>
    <div id="search-resultbox" style="display: none;" class="modal-content">
        <ul id="search-results">
        </ul>
    </div>

    
<div class="row">
    <div class="col-md-3">
                <div id="navigation" class="list-group"><a class="list-group-item active" href="#navigation-10640" data-toggle="collapse" data-parent="#navigation">yii\bootstrap <b class="caret"></b></a><div id="navigation-10640" class="submenu panel-collapse collapse in"><a class="list-group-item" href="./yii-bootstrap-activefield.html">ActiveField</a>
<a class="list-group-item active" href="./yii-bootstrap-activeform.html">ActiveForm</a>
<a class="list-group-item" href="./yii-bootstrap-alert.html">Alert</a>
<a class="list-group-item" href="./yii-bootstrap-basehtml.html">BaseHtml</a>
<a class="list-group-item" href="./yii-bootstrap-bootstrapasset.html">BootstrapAsset</a>
<a class="list-group-item" href="./yii-bootstrap-bootstrappluginasset.html">BootstrapPluginAsset</a>
<a class="list-group-item" href="./yii-bootstrap-bootstrapthemeasset.html">BootstrapThemeAsset</a>
<a class="list-group-item" href="./yii-bootstrap-bootstrapwidgettrait.html">BootstrapWidgetTrait</a>
<a class="list-group-item" href="./yii-bootstrap-button.html">Button</a>
<a class="list-group-item" href="./yii-bootstrap-buttondropdown.html">ButtonDropdown</a>
<a class="list-group-item" href="./yii-bootstrap-buttongroup.html">ButtonGroup</a>
<a class="list-group-item" href="./yii-bootstrap-carousel.html">Carousel</a>
<a class="list-group-item" href="./yii-bootstrap-collapse.html">Collapse</a>
<a class="list-group-item" href="./yii-bootstrap-dropdown.html">Dropdown</a>
<a class="list-group-item" href="./yii-bootstrap-html.html">Html</a>
<a class="list-group-item" href="./yii-bootstrap-inputwidget.html">InputWidget</a>
<a class="list-group-item" href="./yii-bootstrap-modal.html">Modal</a>
<a class="list-group-item" href="./yii-bootstrap-nav.html">Nav</a>
<a class="list-group-item" href="./yii-bootstrap-navbar.html">NavBar</a>
<a class="list-group-item" href="./yii-bootstrap-progress.html">Progress</a>
<a class="list-group-item" href="./yii-bootstrap-tabs.html">Tabs</a>
<a class="list-group-item" href="./yii-bootstrap-togglebuttongroup.html">ToggleButtonGroup</a>
<a class="list-group-item" href="./yii-bootstrap-widget.html">Widget</a></div></div>    </div>
    <div class="col-md-9 api-content" role="main">
        <h1>Class yii\bootstrap\ActiveForm</h1>
<div class="top-nav">
    <a href="index.html">All Classes</a>
            | <a href="#properties">Properties</a>
                | <a href="#methods">Methods</a>
            </div>

<table class="summaryTable docClass table table-bordered">
    <colgroup>
        <col class="col-name" />
        <col class="col-value" />
    </colgroup>
            <tr><th>Inheritance</th><td><a href="yii-bootstrap-activeform.html">yii\bootstrap\ActiveForm</a> &raquo;
<a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a> &raquo;
<a href="yii-base-widget.html">yii\base\Widget</a> &raquo;
<a href="yii-base-component.html">yii\base\Component</a> &raquo;
<a href="yii-base-object.html">yii\base\Object</a></td></tr>
                <tr><th>Implements</th><td><a href="yii-base-configurable.html">yii\base\Configurable</a>, <a href="yii-base-viewcontextinterface.html">yii\base\ViewContextInterface</a></td></tr>
                                    <tr><th>Available since version</th><td>2.0</td></tr>
                    <tr>
          <th>Source Code</th>
          <td><a href="https://github.com/yiisoft/yii2-bootstrap/blob/master/ActiveForm.php">https://github.com/yiisoft/yii2-bootstrap/blob/master/ActiveForm.php</a></td>
        </tr>
    </table>

<div class="class-description">
    <p><strong>A Bootstrap 3 enhanced version of <a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a>.</strong></p>
    <p>This class mainly adds the <a href="yii-bootstrap-activeform.html#$layout-detail">$layout</a> property to choose a Bootstrap 3 form layout.
So for example to render a horizontal form you would:</p>
<pre><code class="hljs php language-php"><span class="hljs-keyword">use</span> <span class="hljs-title">yii</span>\<span class="hljs-title">bootstrap</span>\<span class="hljs-title">ActiveForm</span>;

<span class="hljs-variable">$form</span> = ActiveForm::begin([<span class="hljs-string">'layout'</span> =&gt; <span class="hljs-string">'horizontal'</span>])
</code></pre>
<p>This will set default values for the <a href="yii-bootstrap-activefield.html">yii\bootstrap\ActiveField</a>
to render horizontal form fields. In particular the <a href="yii-widgets-activefield.html#$template-detail">template</a>
is set to <code>{label} {beginWrapper} {input} {error} {endWrapper} {hint}</code> and the
<a href="yii-bootstrap-activefield.html#$horizontalCssClasses-detail">horizontalCssClasses</a> are set to:</p>
<pre><code class="hljs php language-php">[
    <span class="hljs-string">'offset'</span> =&gt; <span class="hljs-string">'col-sm-offset-3'</span>,
    <span class="hljs-string">'label'</span> =&gt; <span class="hljs-string">'col-sm-3'</span>,
    <span class="hljs-string">'wrapper'</span> =&gt; <span class="hljs-string">'col-sm-6'</span>,
    <span class="hljs-string">'error'</span> =&gt; <span class="hljs-string">''</span>,
    <span class="hljs-string">'hint'</span> =&gt; <span class="hljs-string">'col-sm-3'</span>,
]
</code></pre>
<p>To get a different column layout in horizontal mode you can modify those options
through <a href="yii-widgets-activeform.html#$fieldConfig-detail">$fieldConfig</a>:</p>
<pre><code class="hljs php language-php"><span class="hljs-variable">$form</span> = ActiveForm::begin([
    <span class="hljs-string">'layout'</span> =&gt; <span class="hljs-string">'horizontal'</span>,
    <span class="hljs-string">'fieldConfig'</span> =&gt; [
        <span class="hljs-string">'template'</span> =&gt; <span class="hljs-string">"{label}\n{beginWrapper}\n{input}\n{hint}\n{error}\n{endWrapper}"</span>,
        <span class="hljs-string">'horizontalCssClasses'</span> =&gt; [
            <span class="hljs-string">'label'</span> =&gt; <span class="hljs-string">'col-sm-4'</span>,
            <span class="hljs-string">'offset'</span> =&gt; <span class="hljs-string">'col-sm-offset-4'</span>,
            <span class="hljs-string">'wrapper'</span> =&gt; <span class="hljs-string">'col-sm-8'</span>,
            <span class="hljs-string">'error'</span> =&gt; <span class="hljs-string">''</span>,
            <span class="hljs-string">'hint'</span> =&gt; <span class="hljs-string">''</span>,
        ],
    ],
]);
</code></pre>

    <p>See also:</p><ul><li><a href="yii-bootstrap-activefield.html">yii\bootstrap\ActiveField</a> for details on the <a href="yii-widgets-activeform.html#$fieldConfig-detail">$fieldConfig</a> options.</li><li><a href="http://getbootstrap.com/css/#forms">http://getbootstrap.com/css/#forms</a></li></ul></div>

<a id="properties"></a>

<div class="summary doc-property">
<h2>Public Properties</h2>

<p><a href="#" class="toggle">Hide inherited properties</a></p>

<table class="summary-table table table-striped table-bordered table-hover">
<colgroup>
    <col class="col-property" />
    <col class="col-type" />
    <col class="col-description" />
    <col class="col-defined" />
</colgroup>
<tr>
  <th>Property</th><th>Type</th><th>Description</th><th>Defined By</th>
</tr>
        <tr class="inherited" id="$action">
        <td><a href="yii-widgets-activeform.html#$action-detail">$action</a></td>
        <td><a href="http://www.php.net/language.types.array">array</a>|<a href="http://www.php.net/language.types.string">string</a></td>
        <td>The form action URL.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$ajaxDataType">
        <td><a href="yii-widgets-activeform.html#$ajaxDataType-detail">$ajaxDataType</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The type of data that you're expecting back from the server.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$ajaxParam">
        <td><a href="yii-widgets-activeform.html#$ajaxParam-detail">$ajaxParam</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The name of the GET parameter indicating the validation request is an AJAX request.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$attributes">
        <td><a href="yii-widgets-activeform.html#$attributes-detail">$attributes</a></td>
        <td><a href="http://www.php.net/language.types.array">array</a></td>
        <td>The client validation options for individual attributes.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$autoIdPrefix">
        <td><a href="yii-base-widget.html#$autoIdPrefix-detail">$autoIdPrefix</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The prefix to the automatically generated widget IDs.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="$behaviors">
        <td><a href="yii-base-component.html#$behaviors-detail">$behaviors</a></td>
        <td><a href="yii-base-behavior.html">yii\base\Behavior</a>[]</td>
        <td>List of behaviors attached to this component</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="$counter">
        <td><a href="yii-base-widget.html#$counter-detail">$counter</a></td>
        <td><a href="http://www.php.net/language.types.integer">integer</a></td>
        <td>A counter used to generate <a href="yii-base-widget.html#$id-detail">$id</a> for widgets.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="$enableAjaxValidation">
        <td><a href="yii-widgets-activeform.html#$enableAjaxValidation-detail">$enableAjaxValidation</a></td>
        <td><a href="http://www.php.net/language.types.boolean">boolean</a></td>
        <td>Whether to enable AJAX-based data validation.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$enableClientScript">
        <td><a href="yii-widgets-activeform.html#$enableClientScript-detail">$enableClientScript</a></td>
        <td><a href="http://www.php.net/language.types.boolean">boolean</a></td>
        <td>Whether to hook up yii.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$enableClientValidation">
        <td><a href="yii-widgets-activeform.html#$enableClientValidation-detail">$enableClientValidation</a></td>
        <td><a href="http://www.php.net/language.types.boolean">boolean</a></td>
        <td>Whether to enable client-side data validation.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$encodeErrorSummary">
        <td><a href="yii-widgets-activeform.html#$encodeErrorSummary-detail">$encodeErrorSummary</a></td>
        <td><a href="http://www.php.net/language.types.boolean">boolean</a></td>
        <td>Whether to perform encoding on the error summary.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$errorCssClass">
        <td><a href="yii-widgets-activeform.html#$errorCssClass-detail">$errorCssClass</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The CSS class that is added to a field container when the associated attribute has validation error.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$errorSummaryCssClass">
        <td><a href="yii-widgets-activeform.html#$errorSummaryCssClass-detail">$errorSummaryCssClass</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The default CSS class for the error summary container.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr id="$fieldClass">
        <td><a href="yii-bootstrap-activeform.html#$fieldClass-detail">$fieldClass</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The default field class name when calling <a href="yii-bootstrap-activeform.html#field()-detail">field()</a> to create a new field.</td>
        <td><a href="yii-bootstrap-activeform.html">yii\bootstrap\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$fieldConfig">
        <td><a href="yii-widgets-activeform.html#$fieldConfig-detail">$fieldConfig</a></td>
        <td><a href="http://www.php.net/language.types.array">array</a>|<a href="http://www.php.net/class.closure">Closure</a></td>
        <td>The default configuration used by <a href="yii-widgets-activeform.html#field()-detail">field()</a> when creating a new field object.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$id">
        <td><a href="yii-base-widget.html#$id-detail">$id</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>ID of the widget.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr id="$layout">
        <td><a href="yii-bootstrap-activeform.html#$layout-detail">$layout</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The form layout.</td>
        <td><a href="yii-bootstrap-activeform.html">yii\bootstrap\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$method">
        <td><a href="yii-widgets-activeform.html#$method-detail">$method</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The form submission method.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr id="$options">
        <td><a href="yii-bootstrap-activeform.html#$options-detail">$options</a></td>
        <td><a href="http://www.php.net/language.types.array">array</a></td>
        <td>HTML attributes for the form tag.</td>
        <td><a href="yii-bootstrap-activeform.html">yii\bootstrap\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$requiredCssClass">
        <td><a href="yii-widgets-activeform.html#$requiredCssClass-detail">$requiredCssClass</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The CSS class that is added to a field container when the associated attribute is required.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$scrollToError">
        <td><a href="yii-widgets-activeform.html#$scrollToError-detail">$scrollToError</a></td>
        <td><a href="http://www.php.net/language.types.boolean">boolean</a></td>
        <td>Whether to scroll to the first error after validation.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$stack">
        <td><a href="yii-base-widget.html#$stack-detail">$stack</a></td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a>[]</td>
        <td>The widgets that are currently being rendered (not ended).</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="$successCssClass">
        <td><a href="yii-widgets-activeform.html#$successCssClass-detail">$successCssClass</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The CSS class that is added to a field container when the associated attribute is successfully validated.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$validateOnBlur">
        <td><a href="yii-widgets-activeform.html#$validateOnBlur-detail">$validateOnBlur</a></td>
        <td><a href="http://www.php.net/language.types.boolean">boolean</a></td>
        <td>Whether to perform validation when an input field loses focus.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$validateOnChange">
        <td><a href="yii-widgets-activeform.html#$validateOnChange-detail">$validateOnChange</a></td>
        <td><a href="http://www.php.net/language.types.boolean">boolean</a></td>
        <td>Whether to perform validation when the value of an input field is changed.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$validateOnSubmit">
        <td><a href="yii-widgets-activeform.html#$validateOnSubmit-detail">$validateOnSubmit</a></td>
        <td><a href="http://www.php.net/language.types.boolean">boolean</a></td>
        <td>Whether to perform validation when the form is submitted.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$validateOnType">
        <td><a href="yii-widgets-activeform.html#$validateOnType-detail">$validateOnType</a></td>
        <td><a href="http://www.php.net/language.types.boolean">boolean</a></td>
        <td>Whether to perform validation while the user is typing in an input field.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$validatingCssClass">
        <td><a href="yii-widgets-activeform.html#$validatingCssClass-detail">$validatingCssClass</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The CSS class that is added to a field container when the associated attribute is being validated.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$validationDelay">
        <td><a href="yii-widgets-activeform.html#$validationDelay-detail">$validationDelay</a></td>
        <td><a href="http://www.php.net/language.types.integer">integer</a></td>
        <td>Number of milliseconds that the validation should be delayed when the user types in the field
and <a href="yii-widgets-activeform.html#$validateOnType-detail">$validateOnType</a> is set true.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$validationUrl">
        <td><a href="yii-widgets-activeform.html#$validationUrl-detail">$validationUrl</a></td>
        <td><a href="http://www.php.net/language.types.array">array</a>|<a href="http://www.php.net/language.types.string">string</a></td>
        <td>The URL for performing AJAX-based validation.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="$view">
        <td><a href="yii-base-widget.html#$view-detail">$view</a></td>
        <td><a href="yii-web-view.html">yii\web\View</a></td>
        <td>The view object that can be used to render views or view files.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="$viewPath">
        <td><a href="yii-base-widget.html#$viewPath-detail">$viewPath</a></td>
        <td><a href="http://www.php.net/language.types.string">string</a></td>
        <td>The directory containing the view files for this widget.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
    </table>
</div>

<a id="methods"></a>

<div class="summary doc-method">
<h2>Public Methods</h2>

<p><a href="#" class="toggle">Hide inherited methods</a></p>

<table class="summary-table table table-striped table-bordered table-hover">
<colgroup>
    <col class="col-method" />
    <col class="col-description" />
    <col class="col-defined" />
</colgroup>
<tr>
  <th>Method</th><th>Description</th><th>Defined By</th>
</tr>
        <tr class="inherited" id="__call()">
        <td><a href="yii-base-object.html#__call()-detail">__call()</a></td>
        <td>Calls the named method which is not a class method.</td>
        <td><a href="yii-base-object.html">yii\base\Object</a></td>
    </tr>
            <tr class="inherited" id="__clone()">
        <td><a href="yii-base-component.html#__clone()-detail">__clone()</a></td>
        <td>This method is called after the object is created by cloning an existing one.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="__construct()">
        <td><a href="yii-base-object.html#__construct()-detail">__construct()</a></td>
        <td>Constructor.</td>
        <td><a href="yii-base-object.html">yii\base\Object</a></td>
    </tr>
            <tr class="inherited" id="__get()">
        <td><a href="yii-base-object.html#__get()-detail">__get()</a></td>
        <td>Returns the value of an object property.</td>
        <td><a href="yii-base-object.html">yii\base\Object</a></td>
    </tr>
            <tr class="inherited" id="__isset()">
        <td><a href="yii-base-object.html#__isset()-detail">__isset()</a></td>
        <td>Checks if a property is set, i.e. defined and not null.</td>
        <td><a href="yii-base-object.html">yii\base\Object</a></td>
    </tr>
            <tr class="inherited" id="__set()">
        <td><a href="yii-base-object.html#__set()-detail">__set()</a></td>
        <td>Sets value of an object property.</td>
        <td><a href="yii-base-object.html">yii\base\Object</a></td>
    </tr>
            <tr class="inherited" id="__unset()">
        <td><a href="yii-base-object.html#__unset()-detail">__unset()</a></td>
        <td>Sets an object property to null.</td>
        <td><a href="yii-base-object.html">yii\base\Object</a></td>
    </tr>
            <tr class="inherited" id="attachBehavior()">
        <td><a href="yii-base-component.html#attachBehavior()-detail">attachBehavior()</a></td>
        <td>Attaches a behavior to this component.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="attachBehaviors()">
        <td><a href="yii-base-component.html#attachBehaviors()-detail">attachBehaviors()</a></td>
        <td>Attaches a list of behaviors to the component.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="begin()">
        <td><a href="yii-base-widget.html#begin()-detail">begin()</a></td>
        <td>Begins a widget.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="beginField()">
        <td><a href="yii-widgets-activeform.html#beginField()-detail">beginField()</a></td>
        <td>Begins a form field.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="behaviors()">
        <td><a href="yii-base-component.html#behaviors()-detail">behaviors()</a></td>
        <td>Returns a list of behaviors that this component should behave as.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="canGetProperty()">
        <td><a href="yii-base-object.html#canGetProperty()-detail">canGetProperty()</a></td>
        <td>Returns a value indicating whether a property can be read.</td>
        <td><a href="yii-base-object.html">yii\base\Object</a></td>
    </tr>
            <tr class="inherited" id="canSetProperty()">
        <td><a href="yii-base-object.html#canSetProperty()-detail">canSetProperty()</a></td>
        <td>Returns a value indicating whether a property can be set.</td>
        <td><a href="yii-base-object.html">yii\base\Object</a></td>
    </tr>
            <tr class="inherited" id="className()">
        <td><a href="yii-base-object.html#className()-detail">className()</a></td>
        <td>Returns the fully qualified name of this class.</td>
        <td><a href="yii-base-object.html">yii\base\Object</a></td>
    </tr>
            <tr class="inherited" id="detachBehavior()">
        <td><a href="yii-base-component.html#detachBehavior()-detail">detachBehavior()</a></td>
        <td>Detaches a behavior from the component.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="detachBehaviors()">
        <td><a href="yii-base-component.html#detachBehaviors()-detail">detachBehaviors()</a></td>
        <td>Detaches all behaviors from the component.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="end()">
        <td><a href="yii-base-widget.html#end()-detail">end()</a></td>
        <td>Ends a widget.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="endField()">
        <td><a href="yii-widgets-activeform.html#endField()-detail">endField()</a></td>
        <td>Ends a form field.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="ensureBehaviors()">
        <td><a href="yii-base-component.html#ensureBehaviors()-detail">ensureBehaviors()</a></td>
        <td>Makes sure that the behaviors declared in <a href="yii-base-component.html#behaviors()-detail">behaviors()</a> are attached to this component.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="errorSummary()">
        <td><a href="yii-widgets-activeform.html#errorSummary()-detail">errorSummary()</a></td>
        <td>Generates a summary of the validation errors.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr id="field()">
        <td><a href="yii-bootstrap-activeform.html#field()-detail">field()</a></td>
        <td>Generates a form field.</td>
        <td><a href="yii-bootstrap-activeform.html">yii\bootstrap\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="getBehavior()">
        <td><a href="yii-base-component.html#getBehavior()-detail">getBehavior()</a></td>
        <td>Returns the named behavior object.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="getBehaviors()">
        <td><a href="yii-base-component.html#getBehaviors()-detail">getBehaviors()</a></td>
        <td>Returns all behaviors attached to this component.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
                <tr class="inherited" id="getId()">
        <td><a href="yii-base-widget.html#getId()-detail">getId()</a></td>
        <td>Returns the ID of the widget.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="getView()">
        <td><a href="yii-base-widget.html#getView()-detail">getView()</a></td>
        <td>Returns the view object that can be used to render views or view files.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="getViewPath()">
        <td><a href="yii-base-widget.html#getViewPath()-detail">getViewPath()</a></td>
        <td>Returns the directory containing the view files for this widget.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="hasEventHandlers()">
        <td><a href="yii-base-component.html#hasEventHandlers()-detail">hasEventHandlers()</a></td>
        <td>Returns a value indicating whether there is any handler attached to the named event.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="hasMethod()">
        <td><a href="yii-base-object.html#hasMethod()-detail">hasMethod()</a></td>
        <td>Returns a value indicating whether a method is defined.</td>
        <td><a href="yii-base-object.html">yii\base\Object</a></td>
    </tr>
            <tr class="inherited" id="hasProperty()">
        <td><a href="yii-base-object.html#hasProperty()-detail">hasProperty()</a></td>
        <td>Returns a value indicating whether a property is defined.</td>
        <td><a href="yii-base-object.html">yii\base\Object</a></td>
    </tr>
            <tr id="init()">
        <td><a href="yii-bootstrap-activeform.html#init()-detail">init()</a></td>
        <td>Initializes the widget.</td>
        <td><a href="yii-bootstrap-activeform.html">yii\bootstrap\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="off()">
        <td><a href="yii-base-component.html#off()-detail">off()</a></td>
        <td>Detaches an existing event handler from this component.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="on()">
        <td><a href="yii-base-component.html#on()-detail">on()</a></td>
        <td>Attaches an event handler to an event.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="render()">
        <td><a href="yii-base-widget.html#render()-detail">render()</a></td>
        <td>Renders a view.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="renderFile()">
        <td><a href="yii-base-widget.html#renderFile()-detail">renderFile()</a></td>
        <td>Renders a view file.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="run()">
        <td><a href="yii-widgets-activeform.html#run()-detail">run()</a></td>
        <td>Runs the widget.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="setId()">
        <td><a href="yii-base-widget.html#setId()-detail">setId()</a></td>
        <td>Sets the ID of the widget.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="setView()">
        <td><a href="yii-base-widget.html#setView()-detail">setView()</a></td>
        <td>Sets the view object to be used by this widget.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
            <tr class="inherited" id="trigger()">
        <td><a href="yii-base-component.html#trigger()-detail">trigger()</a></td>
        <td>Triggers an event.</td>
        <td><a href="yii-base-component.html">yii\base\Component</a></td>
    </tr>
            <tr class="inherited" id="validate()">
        <td><a href="yii-widgets-activeform.html#validate()-detail">validate()</a></td>
        <td>Validates one or several models and returns an error message array indexed by the attribute IDs.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="validateMultiple()">
        <td><a href="yii-widgets-activeform.html#validateMultiple()-detail">validateMultiple()</a></td>
        <td>Validates an array of model instances and returns an error message array indexed by the attribute IDs.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
            <tr class="inherited" id="widget()">
        <td><a href="yii-base-widget.html#widget()-detail">widget()</a></td>
        <td>Creates a widget instance and runs it.</td>
        <td><a href="yii-base-widget.html">yii\base\Widget</a></td>
    </tr>
    </table>
</div>

<div class="summary doc-method">
<h2>Protected Methods</h2>

<p><a href="#" class="toggle">Hide inherited methods</a></p>

<table class="summary-table table table-striped table-bordered table-hover">
<colgroup>
    <col class="col-method" />
    <col class="col-description" />
    <col class="col-defined" />
</colgroup>
<tr>
  <th>Method</th><th>Description</th><th>Defined By</th>
</tr>
                                                                                                        <tr class="inherited" id="getClientOptions()">
        <td><a href="yii-widgets-activeform.html#getClientOptions()-detail">getClientOptions()</a></td>
        <td>Returns the options for the form JS widget.</td>
        <td><a href="yii-widgets-activeform.html">yii\widgets\ActiveForm</a></td>
    </tr>
                                                                            </table>
</div>

<a id="events"></a>

<a id="constants"></a>

<h2>Property Details</h2>

<div class="property-doc">

    <div class="detail-header h3" id="$fieldClass-detail">
        <a href="#" class="tool-link" title="go to top"><span class="glyphicon glyphicon-arrow-up"></span></a>
        <a class="tool-link hash" href="yii-bootstrap-activeform.html#$fieldClass-detail" title="direct link to this method"><span class="glyphicon icon-hash"></span></a>
                    <a href="https://github.com/yiisoft/yii2-bootstrap/edit/master/ActiveForm.php#L71" class="tool-link" title="edit on github"><span class="glyphicon glyphicon-pencil"></span></a>
            <a href="https://github.com/yiisoft/yii2-bootstrap/blob/master/ActiveForm.php#L71" class="tool-link" title="view source on github"><span class="glyphicon glyphicon-eye-open"></span></a>
        
        $fieldClass        <span class="detail-header-tag small">
            public                                                property
                    </span>
    </div>

    <div class="doc-description">
        <p>The default field class name when calling <a href="yii-bootstrap-activeform.html#field()-detail">field()</a> to create a new field.</p>

        <p>See also <a href="yii-widgets-activeform.html#$fieldConfig-detail">$fieldConfig</a>.</p>    </div>

    <div class="signature"><span class="signature-defs">public</span> <span class="signature-type"><a href="http://www.php.net/language.types.string">string</a></span> <a href="yii-bootstrap-activeform.html#$fieldClass-detail">$fieldClass</a> <span style="color: #0000BB"></span><span style="color: #007700">=&nbsp;</span><span style="color: #DD0000">'yii\bootstrap\ActiveField'</span></div>


    <div class="detail-header h3" id="$layout-detail">
        <a href="#" class="tool-link" title="go to top"><span class="glyphicon glyphicon-arrow-up"></span></a>
        <a class="tool-link hash" href="yii-bootstrap-activeform.html#$layout-detail" title="direct link to this method"><span class="glyphicon icon-hash"></span></a>
                    <a href="https://github.com/yiisoft/yii2-bootstrap/edit/master/ActiveForm.php#L83" class="tool-link" title="edit on github"><span class="glyphicon glyphicon-pencil"></span></a>
            <a href="https://github.com/yiisoft/yii2-bootstrap/blob/master/ActiveForm.php#L83" class="tool-link" title="view source on github"><span class="glyphicon glyphicon-eye-open"></span></a>
        
        $layout        <span class="detail-header-tag small">
            public                                                property
                    </span>
    </div>

    <div class="doc-description">
        <p>The form layout. Either 'default', 'horizontal' or 'inline'.
By choosing a layout, an appropriate default field configuration is applied. This will
render the form fields with slightly different markup for each layout. You can
override these defaults through <a href="yii-widgets-activeform.html#$fieldConfig-detail">$fieldConfig</a>.</p>

        <p>See also <a href="yii-bootstrap-activefield.html">yii\bootstrap\ActiveField</a> for details on Bootstrap 3 field configuration.</p>    </div>

    <div class="signature"><span class="signature-defs">public</span> <span class="signature-type"><a href="http://www.php.net/language.types.string">string</a></span> <a href="yii-bootstrap-activeform.html#$layout-detail">$layout</a> <span style="color: #0000BB"></span><span style="color: #007700">=&nbsp;</span><span style="color: #DD0000">'default'</span></div>


    <div class="detail-header h3" id="$options-detail">
        <a href="#" class="tool-link" title="go to top"><span class="glyphicon glyphicon-arrow-up"></span></a>
        <a class="tool-link hash" href="yii-bootstrap-activeform.html#$options-detail" title="direct link to this method"><span class="glyphicon icon-hash"></span></a>
                    <a href="https://github.com/yiisoft/yii2-bootstrap/edit/master/ActiveForm.php#L75" class="tool-link" title="edit on github"><span class="glyphicon glyphicon-pencil"></span></a>
            <a href="https://github.com/yiisoft/yii2-bootstrap/blob/master/ActiveForm.php#L75" class="tool-link" title="view source on github"><span class="glyphicon glyphicon-eye-open"></span></a>
        
        $options        <span class="detail-header-tag small">
            public                                                property
                    </span>
    </div>

    <div class="doc-description">
        <p>HTML attributes for the form tag. Default is <code>['role' =&gt; 'form']</code>.</p>

            </div>

    <div class="signature"><span class="signature-defs">public</span> <span class="signature-type"><a href="http://www.php.net/language.types.array">array</a></span> <a href="yii-bootstrap-activeform.html#$options-detail">$options</a> <span style="color: #0000BB"></span><span style="color: #007700">=&nbsp;[</span><span style="color: #DD0000">'role'&nbsp;</span><span style="color: #007700">=&gt;&nbsp;</span><span style="color: #DD0000">'form'</span><span style="color: #007700">]</span></div>

</div>
<h2>Method Details</h2>

<div class="method-doc">

    <div class="detail-header h3" id="field()-detail">
        <a href="#" class="tool-link" title="go to top"><span class="glyphicon glyphicon-arrow-up"></span></a>
        <a class="tool-link hash" href="yii-bootstrap-activeform.html#field()-detail" title="direct link to this method"><span class="glyphicon icon-hash"></span></a>
                    <a href="https://github.com/yiisoft/yii2-bootstrap/edit/master/ActiveForm.php#L105" class="tool-link" title="edit on github"><span class="glyphicon glyphicon-pencil"></span></a>
            <a href="https://github.com/yiisoft/yii2-bootstrap/blob/master/ActiveForm.php#L105" class="tool-link" title="view source on github"><span class="glyphicon glyphicon-eye-open"></span></a>
        
        field()
        <span class="detail-header-tag small">
            public                                    method
                    </span>
    </div>

    <div class="doc-description">
        <p><strong>Generates a form field.</strong></p>

        <p>A form field is associated with a model and an attribute. It contains a label, an input and an error message
and use them to interact with end users to collect their inputs for the attribute.</p>

            </div>

    <table class="detail-table table table-striped table-bordered table-hover">
        <tr><td colspan="3" class="signature"><span class="signature-defs">public</span> <span class="signature-type"><a href="yii-bootstrap-activefield.html">yii\bootstrap\ActiveField</a></span> <strong><a href="yii-bootstrap-activeform.html#field()-detail">field</a></strong> ( <span style="color: #0000BB">$model</span>, <span style="color: #0000BB">$attribute</span>, <span style="color: #0000BB">$options&nbsp;</span><span style="color: #007700">=&nbsp;[]</span> )</td></tr>
                                    <tr>
                  <td class="param-name-col"><span style="color: #0000BB">$model</span></td>
                  <td class="param-type-col"><a href="yii-base-model.html">yii\base\Model</a></td>
                  <td class="param-desc-col"><p>The data model</p>
</td>
                </tr>
                            <tr>
                  <td class="param-name-col"><span style="color: #0000BB">$attribute</span></td>
                  <td class="param-type-col"><a href="http://www.php.net/language.types.string">string</a></td>
                  <td class="param-desc-col"><p>The attribute name or expression. See <a href="yii-helpers-basehtml.html#getAttributeName()-detail">yii\bootstrap\Html::getAttributeName()</a> for the format
about attribute expression.</p>
</td>
                </tr>
                            <tr>
                  <td class="param-name-col"><span style="color: #0000BB">$options</span></td>
                  <td class="param-type-col"><a href="http://www.php.net/language.types.array">array</a></td>
                  <td class="param-desc-col"><p>The additional configurations for the field object. These are properties of <a href="yii-bootstrap-activefield.html">yii\bootstrap\ActiveField</a>
or a subclass, depending on the value of <a href="yii-bootstrap-activeform.html#$fieldClass-detail">$fieldClass</a>.</p>
</td>
                </tr>
                                        <tr>
                  <th class="param-name-col">return</th>
                  <td class="param-type-col"><a href="yii-bootstrap-activefield.html">yii\bootstrap\ActiveField</a></td>
                  <td class="param-desc-col"><p>The created ActiveField object</p>
</td>
                </tr>
                                    </table>

<!--	-->

    <div class="detail-header h3" id="init()-detail">
        <a href="#" class="tool-link" title="go to top"><span class="glyphicon glyphicon-arrow-up"></span></a>
        <a class="tool-link hash" href="yii-bootstrap-activeform.html#init()-detail" title="direct link to this method"><span class="glyphicon icon-hash"></span></a>
                    <a href="https://github.com/yiisoft/yii2-bootstrap/edit/master/ActiveForm.php#L89" class="tool-link" title="edit on github"><span class="glyphicon glyphicon-pencil"></span></a>
            <a href="https://github.com/yiisoft/yii2-bootstrap/blob/master/ActiveForm.php#L89" class="tool-link" title="view source on github"><span class="glyphicon glyphicon-eye-open"></span></a>
        
        init()
        <span class="detail-header-tag small">
            public                                    method
                    </span>
    </div>

    <div class="doc-description">
        <p><strong>Initializes the widget.</strong></p>

        <p>This renders the form open tag.</p>

            </div>

    <table class="detail-table table table-striped table-bordered table-hover">
        <tr><td colspan="3" class="signature"><span class="signature-defs">public</span> <span class="signature-type">void</span> <strong><a href="yii-bootstrap-activeform.html#init()-detail">init</a></strong> ( )</td></tr>
            </table>

<!--	-->
</div>
        </div>
</div>

<script type="text/javascript">
    /*<![CDATA[*/
    $("a.toggle").on('click', function () {
        var $this = $(this);
        if ($this.hasClass('properties-hidden')) {
            $this.text($this.text().replace(/Show/,'Hide'));
            $this.parents(".summary").find(".inherited").show();
            $this.removeClass('properties-hidden');
        } else {
            $this.text($this.text().replace(/Hide/,'Show'));
            $this.parents(".summary").find(".inherited").hide();
            $this.addClass('properties-hidden');
        }

        return false;
    });
    /*
     $(".sourceCode a.show").toggle(function () {
     $(this).text($(this).text().replace(/show/,'hide'));
     $(this).parents(".sourceCode").find("div.code").show();
     },function () {
     $(this).text($(this).text().replace(/hide/,'show'));
     $(this).parents(".sourceCode").find("div.code").hide();
     });
     $("a.sourceLink").click(function () {
     $(this).attr('target','_blank');
     });
     */
    /*]]>*/
</script>


</div>

<footer class="footer">
        <p class="pull-right"><small>Page generated on Sat, 09 Jul 2016 12:15:52 +0000</small></p>
    Powered by <a href="http://www.yiiframework.com/" rel="external">Yii Framework</a></footer>

<script type="text/javascript">jQuery(document).ready(function () {
    var shiftWindow = function () { scrollBy(0, -50) };
    if (location.hash) setTimeout(shiftWindow, 1);
    window.addEventListener("hashchange", shiftWindow);
var element = document.createElement("script");
element.src = "./jssearch.index.js";
document.body.appendChild(element);

var searchBox = $('#searchbox');

// search when typing in search field
searchBox.on("keyup", function(event) {
    var query = $(this).val();

    if (query == '' || event.which == 27) {
        $('#search-resultbox').hide();
        return;
    } else if (event.which == 13) {
        var selectedLink = $('#search-resultbox a.selected');
        if (selectedLink.length != 0) {
            document.location = selectedLink.attr('href');
            return;
        }
    } else if (event.which == 38 || event.which == 40) {
        $('#search-resultbox').show();

        var selected = $('#search-resultbox a.selected');
        if (selected.length == 0) {
            $('#search-results').find('a').first().addClass('selected');
        } else {
            var next;
            if (event.which == 40) {
                next = selected.parent().next().find('a').first();
            } else {
                next = selected.parent().prev().find('a').first();
            }
            if (next.length != 0) {
                var resultbox = $('#search-results');
                var position = next.position();

//              TODO scrolling is buggy and jumps around
//                resultbox.scrollTop(Math.floor(position.top));
//                console.log(position.top);

                selected.removeClass('selected');
                next.addClass('selected');
            }
        }

        return;
    }
    $('#search-resultbox').show();
    $('#search-results').html('<li><span class="no-results">No results</span></li>');

    var result = jssearch.search(query);

    if (result.length > 0) {
        var i = 0;
        var resHtml = '';

        for (var key in result) {
            if (i++ > 20) {
                break;
            }
            resHtml = resHtml +
            '<li><a href="' + result[key].file.u.substr(3) +'"><span class="title">' + result[key].file.t + '</span>' +
            '<span class="description">' + result[key].file.d + '</span></a></li>';
        }
        $('#search-results').html(resHtml);
    }
});

// hide the search results on ESC
$(document).on("keyup", function(event) { if (event.which == 27) { $('#search-resultbox').hide(); } });
// hide search results on click to document
$(document).bind('click', function (e) { $('#search-resultbox').hide(); });
// except the following:
searchBox.bind('click', function(e) { e.stopPropagation(); });
$('#search-resultbox').bind('click', function(e) { e.stopPropagation(); });

});</script></body>
</html>
